//
//  KZBannerView.h
//  KZTools_ObjectC
//
//  Created by 朱凯 on 2018/11/26.
//  Copyright © 2018年 zhukai. All rights reserved.
//

#import <UIKit/UIKit.h>


typedef enum : NSUInteger {
    KZBannerViewPageControllerPositionNone,
    KZBannerViewPageControllerPositionTopLeft,
    KZBannerViewPageControllerPositionTopCenter,
    KZBannerViewPageControllerPositionTopRight,
    KZBannerViewPageControllerPositionBottomLeft,
    KZBannerViewPageControllerPositionBottomCenter,
    KZBannerViewPageControllerPositionBottomRight,
} KZBannerViewPageControllerPosition;

@protocol KZBannerViewDatasource <NSObject>

@required
/**
 横幅数量
 */
- (NSInteger)numOfBanners;
/**
 对应横幅页的视图
 */
- (UIView *)bannerAtIndex:(NSInteger)index;

@optional
/**
 两侧横幅的缩放值，单位元
 */
- (CGPoint)bannerSideScale;

/**
 pageController的位置
 */
- (KZBannerViewPageControllerPosition)bannerPageControllerPosition;
@end

@interface KZBannerView : UIView <UIScrollViewDelegate>

/**
 数据源代理
 */
@property (nonatomic, assign) id<KZBannerViewDatasource> datasource;

/**
 默认状态下的page颜色
 */
@property (nonatomic, strong) UIColor *pageIndicatorTintColor;
/**
 当前选中下的page颜色
 */
@property (nonatomic, strong) UIColor *currentPageIndicatorTintColor;
@end
